package hy;

import com.P;
import hy.beans.Person;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.context.properties.EnableConfigurationProperties;
import org.springframework.context.ConfigurableApplicationContext;
import org.springframework.context.annotation.ImportResource;

//@EnableConfigurationProperties(P.class)
@SpringBootApplication
@ImportResource("classpath:a.xml")
public class Day102Application {

    public static void main(String[] args) {
        ConfigurableApplicationContext run = SpringApplication.run(Day102Application.class, args);
        System.out.println(run.getBean(Person.class));
        for (String n : run.getBeanDefinitionNames()) {
            System.out.println(n);
        }
    }

}
